<template>
    <div>

        <el-table :data="budgetProjectList" :header-cell-style="{ textAlign: 'center' }"
            :cell-style="{ textAlign: 'center' }" border style="width: 100%">
            <el-table-column prop="companyName" label="公司名称" width="110" />
            <el-table-column prop="year" label="年度" />
            <el-table-column prop="budgetCode" label="预算项目编码" width="130" />
            <el-table-column prop="budgetName" label="预算名称" width="200" />
            <el-table-column prop="budgetTotalMoney" label="预算项目总额(元)" width="150" />
        </el-table>

        <div style="text-align:center;"><img :src="require('@/assets/images/relation.png')" alt=""></div>

        <el-table :data="orgBudgets" :header-cell-style="{ textAlign: 'center' }" :cell-style="{ textAlign: 'center' }"
            border style="width: 100%">
            <el-table-column prop="budgetDeptDode" label="预算责任部门" width="150" />
            <el-table-column prop="budgetAccount" label="预算科目" width="150" />
            <el-table-column prop="activityCode" label="业务活动" width="130" />
            <el-table-column prop="activityName" label="业务活动名称" width="200" />
            <el-table-column prop="budgetYear" label="预算使用年份" width="110" />
            <el-table-column prop="activityTax" label="业务活动税率(%)" width="150" />
            <el-table-column prop="declareNoAmount" label="申报不含税金额(元)" width="150" />
            <el-table-column prop="declareAmount" label="申报含税金额(元)" width="150" />
        </el-table>


    </div>
</template>

<script>

export default {

    props: {

        budgetProject: {
            type: Map,
            default: () => {},
        }
    },

    computed: {

        /// 公司数据（单条）
        budgetProjectList() {

            var list = new Array();
            list.push(this.budgetProject);
            return list;
        },

        /// 公司下的部门数据
        orgBudgets() {

            let budgetList = this.budgetProject.budgetList;
            if (!budgetList) {
                budgetList = [];
            }

            return budgetList;
        }
    }


}

</script>

